<template>
    <el-form :inline="true" size="small">
        <el-form-item>
            <el-input v-model="filter.nameOrNormalizedName" @change="doSearch" type="text">
                <el-button slot="append" @click="doSearch">
                    <i class="el-icon-search"></i> 搜索
                </el-button>
            </el-input>
        </el-form-item>
         
        <el-form-item>
            <el-checkbox v-model="filter.showDeleted" @change="doSearch">显示回收站的分区</el-checkbox>
        </el-form-item>
    </el-form>
</template>

<script>
export default {
    data() {
        return {
           
        }
    },
    props:{filter: Object, default: function(){
        return {nameOrNormalizedName: null, showDeleted: false}
    }},
    model:{event:'search', prop:'filter'},
    methods: {
        doSearch: function(){
            this.$emit('search', this.filter)
        }
    }
};
</script>
